package BehaviorModel.chainOfResponsibilityModel;

/**
 * 功能描述: 董事长审批 x>30000
 * 2024/02/21
 * <p>
 * ZhangYi
 */
public class PresidentHandler extends Handler{

    public PresidentHandler(String name) {
        super(name);
    }

    @Override
    public void handleRequest(PurseRequest purseRequest) {
        if (purseRequest.getPrice() >=30000){
            System.out.println(this.name + "董事长审批" + purseRequest.toString());
        }else {
            nextHandler.handleRequest(purseRequest);
        }
    }
}
